Adding Threshold Columns

A threshold column can identify a column value as above, below, or between values. These values can be determined using hard-coded values or other columns.

For example, here is a report page that includes a column that uses thresholds. The GP$ column uses the Cost column as a basis for low and high thresholds. Using low and high colors makes it easier to visually see if the Cost is greater than or less than the GP$ for a Corporate Brand.

  report-page { 
    title "Report 1" 
    cplan "/cplans/basic_101.cplan" 
    
    quickview-set {
      cplan "/cplans/basic_101.cplan"
      dimension-quickview "Premise"
      dimension-quickview "Resp Team"
    }
    dimension "Corporate Brand"
    
    text column = "Net Sales" 
    text column = "GP$" {
      low-color "B20000"
      high-color "1E911E"
      high-threshold column = "Cost"
      low-threshold column = "Cost"
    }
    text column = "Cost"
  }

Here is the Closedresult in DiveTab.

A threshold column that uses a text column for threshold values.

Notice how the GP$, or Gross Profit Dollars, is written in red text if it is less than the corresponding Cost value and in green text if it is greater than the corresponding Cost value.

Here is an example of a report page that uses hard-coded numerical values

  report-page { 
    title "Report 2" 
    cplan "/cplans/basic_101.cplan" 
    
    quickview-set {
      cplan "/cplans/basic_101.cplan"
      dimension-quickview "Premise"
      dimension-quickview "Resp Team"
    } 
    dimension "Corporate Brand"
    
    text column = "Cases YTD"
    text column = "Cases YTD Y-1"
    text column = "Cases YTD Y-0 Diff" {
      low-color "B20000"
      high-color "1E911E"
      low-threshold 0
      high-threshold 0
    }
    text column = "Cases YTD Y-0 % Diff" {
      low-color "B20000"
      high-color "1E911E"
      low-threshold 0
      high-threshold 0
    } 
  } 

Notice how the low and high thresholds are 0. This means that positive changes appear in green and negative changes in red. Because this particular column is comparing the difference in values between this year and last year, the result is either a positive or negative difference.

Here is the Closedresult of the code in DiveTab.

A threshold column that uses a number value for threshold values.

NOTE: Low and high thresholds, and their corresponding color values, are required to use this feature.

Thresholds are also used with alert and bullet columns.

See also: